#include<stdio.h>
#include<windows.h>
#define maxn 100

int main()
{
	int i,count;
	i=0;
	count=0;
	char s[maxn];
	gets(s);
	while (s[i++]!='\0')
		if ((s[i-1]>='0')&&(s[i-1]<='9'))	count++;
	printf("%d\n",count);
	system("pause");
	return 0;
}
